package com.countryside.service.impl;

import com.countryside.mapper.EmployeeProjectMapper;
import com.countryside.pojo.EmployeeProject;
import com.countryside.service.EmployeeProjectService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class EmployeeProjectServiceImpl implements EmployeeProjectService {

    @Autowired
    EmployeeProjectMapper employeeProjectMapper;

    @Override
    public int addEmployeeProject(EmployeeProject employeeProject) {
        return employeeProjectMapper.addEmployeeProject(employeeProject);
    }

    @Override
    public List<EmployeeProject> getEmployeeProjectByUserId(String userId) {
        return employeeProjectMapper.getEmployeeProjectByUserId(userId);
    }

    @Override
    public int deleteEmployeeProject(int id) {
        return employeeProjectMapper.deleteEmployeeProject(id);
    }

    @Override
    public List<EmployeeProject> queryEmployeeProjectByUserId(String userId) {
        return employeeProjectMapper.queryEmployeeProjectByUserId(userId);
    }
}
